package com.ant.storage.pojo;

import com.ant.storage.vo.CommodityVo;
import com.ant.storage.vo.PurchaseVo;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * <p>
 * 
 * </p>
 *
 * @author melon
 * @since 2022-03-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="Subscribe对象", description="")
public class Subscribe implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @TableField("parent_id")
    private Integer parentId;

    @TableField("city_id")
    private Integer cityId;

    @ApiModelProperty(value = "申请部门")
    @TableField("department_id")
    private Integer departmentId;

    @ApiModelProperty(value = "采购清单编号")
    @TableField("subscribe_number")
    private String subscribeNumber;

    @ApiModelProperty(value = "采购类型")
    @TableField("purchase_type")
    private String purchaseType;

    @ApiModelProperty(value = "数量")
    private Integer total;

    @ApiModelProperty(value = "消费总金额")
    private BigDecimal price;

    @ApiModelProperty(value = "支付方式")
    @TableField("pay_type")
    private String payType;

    @ApiModelProperty(value = "申请金额")
    @TableField("total_price")
    private BigDecimal totalPrice;

    @ApiModelProperty(value = "采购人id")
    @TableField("purchaser_id")
    private String purchaserId;

    @ApiModelProperty(value = "申请人id")
    @TableField("proposer_id")
    private Integer proposerId;

    @ApiModelProperty(value = "审批id")
    @TableField("process_instance_id")
    private String processInstanceId;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "审核状态  0 提交审核 1  提交审核  2 审核通过  3 审核拒绝")
    @TableField("process_state")
    private Integer processState;

    @ApiModelProperty(value = "要货时间")
    @TableField("delivery_time")
    private Date DeliveryTime;

    @ApiModelProperty(value = "是否合并采购")
    @TableField("is_merge")
    private Integer  isMerge;

    @ApiModelProperty(value = "合并采购id")
    @TableField(exist = false)
    private Integer mergeId;

    @ApiModelProperty(value = "合并采购id")
    @TableField(exist = false)
    private String mergeIds;

    @ApiModelProperty(value = "生成状态 0 待采购 1 采购中 2 取消采购 3 完成采购 4 已入库 4 已签收")
    private String status;

    @ApiModelProperty(value = "请款状态 0 未提交 1 提交中 2 通过  3 拒绝")
    @TableField("pay_status")
    private Integer payStatus;

    @ApiModelProperty(value = "报销状态 0 未报销 1 已申请 2 同意报销  3 拒绝")
    @TableField("reimbursement")
    private Integer reimbursement;

    @ApiModelProperty(value = "票据")
    @TableField("bills")
    private String bills;

    @TableField("creator_by")
    private String creatorBy;

    @TableField("creation_time")
    private Date creationTime;

    @ApiModelProperty(value = "处理人")
    private Integer handlers;


    @ApiModelProperty(value = "处理时间")
    @TableField("handler_time")
    private Date handlerTime;


    @ApiModelProperty(value = "申请信息")
    @TableField(exist = false)
    private List<AuditList> auditList;

    @ApiModelProperty(value = "结算申请信息")
    @TableField(exist = false)
    private List<PurchaserRecord> purchaserRecordList;

    @ApiModelProperty(value = "购物清单列表")
    @TableField(exist = false)
    private List<PurchaseVo> purchaseVoList;

    @ApiModelProperty(value = "购物清单列表2")
    @TableField(exist = false)
    private List<CommodityVo> commodityVoList;

    @ApiModelProperty(value = "票据")
    @TableField(exist = false)
    private List<PurchaserRecordImg> purchaserRecordImgList;

    @ApiModelProperty(value = "支付方式")
    @TableField(exist = false)
    private String payTypeName;

    @ApiModelProperty(value = "分单采购管理")
    @TableField(exist = false)
    private List<MergeSubscribe> mergeSubscribeList;

    @ApiModelProperty(value = "申请部门")
    @TableField(exist = false)
    private String department;
}
